/*
 * Copyright (C) 2023 xuexiangjys(xuexiangjys@163.com)
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *       http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 */

package com.xuexiang.templateproject.bean;
import kotlin.Metadata;
import kotlin.jvm.internal.Intrinsics;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

public final class PageCourse implements IContent {
    private final int courseId;
    @NotNull
    private final String courseName;
    @NotNull
    private final String coverUrl;
    private final boolean homepage;
    private final int notSeeTotal;
    private final int problemSum;
    private final boolean system;

    public PageCourse(int i2, @NotNull String courseName, @NotNull String coverUrl, boolean z, int i3, int i4, boolean z2) {
        Intrinsics.checkNotNullParameter(courseName, "courseName");
        Intrinsics.checkNotNullParameter(coverUrl, "coverUrl");
        this.courseId = i2;
        this.courseName = courseName;
        this.coverUrl = coverUrl;
        this.homepage = z;
        this.notSeeTotal = i3;
        this.problemSum = i4;
        this.system = z2;
    }

    public static /* synthetic */ PageCourse copy$default(PageCourse pageCourse, int i2, String str, String str2, boolean z, int i3, int i4, boolean z2, int i5, Object obj) {
        if ((i5 & 1) != 0) {
            i2 = pageCourse.courseId;
        }
        if ((i5 & 2) != 0) {
            str = pageCourse.courseName;
        }
        if ((i5 & 4) != 0) {
            str2 = pageCourse.coverUrl;
        }
        if ((i5 & 8) != 0) {
            z = pageCourse.homepage;
        }
        if ((i5 & 16) != 0) {
            i3 = pageCourse.notSeeTotal;
        }
        if ((i5 & 32) != 0) {
            i4 = pageCourse.problemSum;
        }
        if ((i5 & 64) != 0) {
            z2 = pageCourse.system;
        }
        return pageCourse.copy(i2, str, str2, z, i3, i4, z2);
    }

    public final int component1() {
        return this.courseId;
    }

    @NotNull
    public final String component2() {
        return this.courseName;
    }

    @NotNull
    public final String component3() {
        return this.coverUrl;
    }

    public final boolean component4() {
        return this.homepage;
    }

    public final int component5() {
        return this.notSeeTotal;
    }

    public final int component6() {
        return this.problemSum;
    }

    public final boolean component7() {
        return this.system;
    }

    @NotNull
    public final PageCourse copy(int i2, @NotNull String courseName, @NotNull String coverUrl, boolean z, int i3, int i4, boolean z2) {
        Intrinsics.checkNotNullParameter(courseName, "courseName");
        Intrinsics.checkNotNullParameter(coverUrl, "coverUrl");
        return new PageCourse(i2, courseName, coverUrl, z, i3, i4, z2);
    }

    public boolean equals(@Nullable Object obj) {
        if (this == obj) {
            return true;
        }
        if (!(obj instanceof PageCourse)) {
            return false;
        }
        PageCourse pageCourse = (PageCourse) obj;
        return this.courseId == pageCourse.courseId && Intrinsics.areEqual(this.courseName, pageCourse.courseName) && Intrinsics.areEqual(this.coverUrl, pageCourse.coverUrl) && this.homepage == pageCourse.homepage && this.notSeeTotal == pageCourse.notSeeTotal && this.problemSum == pageCourse.problemSum && this.system == pageCourse.system;
    }

    public final int getCourseId() {
        return this.courseId;
    }

    @NotNull
    public final String getCourseName() {
        return this.courseName;
    }

    @NotNull
    public final String getCoverUrl() {
        return this.coverUrl;
    }

    public final boolean getHomepage() {
        return this.homepage;
    }

    @Override // com.jcds.learneasy.entity.IContent
    @NotNull
    public String getKey() {
        return this.courseName;
    }

    @Override // com.jcds.learneasy.entity.IContent
    @NotNull
    public String getName() {
        return String.valueOf(this.courseId);
    }

    public final int getNotSeeTotal() {
        return this.notSeeTotal;
    }

    public final int getProblemSum() {
        return this.problemSum;
    }

    public final boolean getSystem() {
        return this.system;
    }

    public int hashCode() {
        int hashCode = ((((this.courseId * 31) + this.courseName.hashCode()) * 31) + this.coverUrl.hashCode()) * 31;
        boolean z = this.homepage;
        int i2 = 1;
        if (z) {
            z = true;
        }
        int i3 = z ? 1 : 0;
        int i4 = z ? 1 : 0;
        int i5 = z ? 1 : 0;
        int i6 = (((((hashCode + i3) * 31) + this.notSeeTotal) * 31) + this.problemSum) * 31;
        boolean z2 = this.system;
        if (!z2) {
            i2 = z2 ? 1 : 0;
        }
        return i6 + i2;
    }

    @NotNull
    public String toString() {
        return "PageCourse(courseId=" + this.courseId + ", courseName=" + this.courseName + ", coverUrl=" + this.coverUrl + ", homepage=" + this.homepage + ", notSeeTotal=" + this.notSeeTotal + ", problemSum=" + this.problemSum + ", system=" + this.system + ')';
    }
}